package com.huang.auth.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.huang.auth.entity.po.AuthRolePO;
import com.huang.auth.entity.request.AuthRoleAddRequest;
import com.huang.auth.entity.request.AuthRoleEditRequest;
import com.huang.auth.entity.request.AuthRoleQueryRequest;
import com.huang.auth.entity.vo.AuthRoleInfoVO;
import com.huang.auth.entity.vo.AuthRoleSimpleVO;

import java.util.List;

/**
 * 角色(AuthRole)表服务接口
 *
 * @author HuangShen
 * @since 2021-09-21 17:13:48
 */
public interface AuthRoleService extends IService<AuthRolePO> {

    /**
     * 获取简单角色列表
     *
     * @return List<AuthRoleSimpleVO>
     */
    List<AuthRoleSimpleVO> roleSimpleList();

    /**
     * 添加角色
     *
     * @param authRoleAddRequest authRoleAddRequest
     * @return authRoleAddRequest
     */
    boolean creatRole(AuthRoleAddRequest authRoleAddRequest);

    /**
     * 根据角色id 获取角色信息
     *
     * @param roleId
     * @return
     */
    AuthRoleInfoVO getRoleInfo(Long roleId);

    /**
     * 角色删除
     *
     * @param roleId 角色id
     * @return boolean
     */
    boolean deleteRoleById(String operatorId, String roleId);

    /**
     * 修改角色信息
     * @param authRoleEditRequest authRoleEditRequest
     * @return boolean
     */
    boolean updateRole(AuthRoleEditRequest authRoleEditRequest);

    /**
     * 角色分页查询
     * @param authRoleQueryRequest
     * @return
     */
    Page<AuthRolePO> getRoleList(AuthRoleQueryRequest authRoleQueryRequest);
}

